package com.tckdq.tcc.feign;

import com.tckdq.tcc.doc.CourseDoc;
import com.tckdq.tcc.result.JsonResult;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

@FeignClient(value = "service-search",fallbackFactory = SearchFeignFallbackFactory.class)
public interface SearchFeignClient {

    @PostMapping("/es/course/save")
    public JsonResult saveCourse(@RequestBody CourseDoc doc);
    @PostMapping("/es/course/delete")
    public JsonResult deleteCourse(@RequestBody Long id);
}
